package com.baoy.cloud.xxx.sso.shiro.session;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.Getter;
import lombok.ToString;
import org.apache.shiro.session.mgt.SimpleSession;

@Data
@ToString
public class RedisSession extends SimpleSession {

    // 用户浏览器类型
    private String userAgent;
    // 在线状态
    private OnlineStatus status = OnlineStatus.off_line;

    @Getter
    @AllArgsConstructor
    public static enum OnlineStatus {
        on_line("在线"),
        off_line("离线"),
        force_logout("强制退出");
        private final String info;
    }

}
